<!DOCTYPE HTML>
<html lang="zh-CN">
<head>
  	<meta charset="UTF-8">
  	<meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0" />
  	<meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
  	<title>省钱教程frm</title>
  	<link rel="stylesheet" type="text/css" href="../../css/api.css" />
    <link rel="stylesheet" type="text/css" href="../../css/aui.css" />
    <link rel="stylesheet" type="text/css" href="../../css/iconfont.css" />
  	<link rel="stylesheet" type="text/css" href="../../css/common.css">
    <style>
    </style>
</head>
<body id="warp">
    <div class="aui-content aui-margin-b-15">
        <img class="courseImg" src="../../image/home/coursetbimg.png" alt="">
    </div>
</body>
<script type="text/javascript" src="../../script/api.js"></script>
<script type="text/javascript">
(function (doc, win) {
  	var docEl = doc.documentElement,
  	resizeEvt = 'orientationchange' in window ? 'orientationchange' : 'resize',
  	recalc = function () {
    		var clientWidth = docEl.clientWidth;
    		if (!clientWidth) return;
    		docEl.style.setProperty('font-size',(clientWidth / 10) + 'px','important');
  	};
  	if(!doc.addEventListener){
        return
    };
  	win.addEventListener(resizeEvt, recalc, false);
  	doc.addEventListener('DOMContentLoaded', recalc, false);
})(document, window);
var app;
apiready = function () {
		//解析元素 tapmode 属性，优化点击事件处理 - 第四步
		api.parseTapmode();
    // 初始化数据
    if(api.systemType == 'ios'){
        document.querySelector(".courseImg").src="../../image/home/coursetbimg.png"
    }else{
        document.querySelector(".courseImg").src="../../image/home/coursetb1img.png"
    }
    api.addEventListener({
        name: 'courseChange'
    }, function(ret, err){
        if( ret ){
            if(ret.value.key == 0){
                if(api.systemType == 'ios'){
                    document.querySelector(".courseImg").src="../../image/home/coursetbimg.png"
                }else{
                    document.querySelector(".courseImg").src="../../image/home/coursetb1img.png"
                }
            }else if(ret.value.key == 1){
                document.querySelector(".courseImg").src="../../image/home/coursepddimg.png"
            }else if(ret.value.key == 2){
                document.querySelector(".courseImg").src="../../image/home/coursejdimg.png"
            }
        }else{
        }
    });
}
</script>
</html>
